package com.example.consumer.controller;

import com.example.consumer.service.OrderService;
import com.example.consumer.service.OrderService2;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/order")
public class OrderController {

    @Autowired
    private OrderService orderService;

    @Autowired
    private OrderService2 orderService2;

    @GetMapping("/one")
    public String getOrder(){
        return  orderService.getOrder();
    }

    @GetMapping("/getone")
    public String getOne(){
        return orderService2.getOne();
    }
}
